perm filename BOOMAC.TEX[B2,JMC]2 blob sn#763037 filedate 1984-07-20 generic text, type C, neo UTF8
COMMENT ⊗   VALID 00006 PAGES
C REC  PAGE   DESCRIPTION
C00001 00001
C00002 00002	% see boo11.sty for fonts, boo.sty, boo.plo for basics
C00003 00003	% clt utilities -  time of day, cltnot, inmmode
C00006 00004	% from manual.tex[tex,dek]
C00010 00005	% bbnotation
C00014 00006	% other
C00028 ENDMK
C⊗;
% see boo11.sty for fonts, boo.sty, boo.plo for basics

% opfam for operators  \op  {bf}
% sxfam for sexpression constants    \sx

% use \pagestyle{boodraftheadings} to get boo draft headings

% clt utilities -  time of day, cltnot, inmmode

\def\inmmode#1{\relax\ifmmode #1\else $#1$\fi}

\newcount\hours
\newcount\minutes
\newcount\temp
\newtoks\ampm

\def\setdaytime{%
   \temp\time 
   \divide\temp 60
   \hours\temp 
   \multiply\temp -60
   \minutes\time 
   \advance\minutes \temp 
   \ifnum\hours = 0 \advance\hours 12  \ampm={a.m.} \else
   \ifnum\hours < 12  \ampm={a.m.} \else
   \ifnum\hours = 12  \ampm={p.m.} \else
    \advance\hours -12 \ampm={p.m.} \fi\fi\fi
}

\setdaytime

\def\Time{\the\hours:\ifnum \minutes < 10 0\fi \the\minutes\ \the\ampm}

% Date
\def\today{\number\day\space
  \ifcase\month\or
    January\or February\or March\or April\or May\or June\or
    July\or August\or September\or October\or November\or December\fi
    \space\number\year}


% making boxes

%  %  \abox{bigline}{vertical stuff}
%  
\def\abox#1#2{\vbox{\settowidth{\hsize}{#1} #2}}
%  
%  %  \frameit{vgap}{hgap}{box}

\def\frameit#1#2#3{\vbox{\hrule\hbox{\vrule\kern #2 
  \vbox{\kern #1 #3 \kern #1}
  \kern #2\vrule}\hrule}}

% \mybox{vgap}{hgap}{bigline}{vertical stuff}

\def\mybox#1#2#3#4{\frameit{#1}{#2}{\abox{#3}{#4}}}

% from manual.tex[tex,dek]

\makeatletter  % to read macros with @
\newskip\ttglue
{\tt \ttglue=.5em plus.25em minus.15em}

\def\|{\leavevmode\hbox{\tt\char`\|}} % vertical line

{\obeyspaces\gdef {\ }}


% macros for verbatim scanning
\chardef\other=12
%  \def\ttverbatim{\begingroup
%    \catcode`\\=\other
%    \catcode`\{=\other
%    \catcode`\}=\other
%    \catcode`\$=\other
%    \catcode`\&=\other
%    \catcode`\#=\other
%    \catcode`\%=\other
%    \catcode`\~=\other
%    \catcode`\/=\other
%    \catcode`\_=\other
%    \catcode`\↑=\other
%    \obeyspaces \obeylines \tt}

% macros for verbatim scanning
\def\ttverbatim{\begingroup
  \catcode`\\=\other
  \catcode`\{=\other
  \catcode`\}=\other
  \catcode`\$=\other
  \catcode`\&=\other
  \catcode`\#=\other
  \catcode`\%=\other
  \catcode`\~=\other
  \catcode`\/=\other
  \catcode`\_=\other
  \catcode`\↑=\other
\mathcode`\!="7021
\mathcode`\'="7027
\mathcode`\(="7028
\mathcode`\)="7029
\mathcode`\*="702A
\mathcode`\+="702B
\mathcode`\,="702C
\mathcode`\-="702D
\mathcode`\.="702E
\mathcode`\/="702F
\mathcode`\:="703A
\mathcode`\;="703B
\mathcode`\<="703C
\mathcode`\=="703D
\mathcode`\>="703E
\mathcode`\?="703F
\mathcode`\[="705B
\mathcode`\\="705C
\mathcode`\]="705D
\mathcode`\_="705F
\mathcode`\{="707B
\mathcode`\}="707D
  \obeyspaces \obeylines \tt}

\def\begintt{$$\let\par=\endgraf \ttverbatim \parskip=\z@
  \catcode`\|=0 \rightskip-5pc \ttfinish}
{\catcode`\|=0 |catcode`|\=\other % | is temporary escape character
  |obeylines % end of line is active
  |gdef|ttfinish#1↑↑M#2\endtt{#1|vbox{#2}|endgroup$$}}

\catcode`\|=\active
{\obeylines \gdef|{\ttverbatim \spaceskip\ttglue \let↑↑M=\  \let|=\endgroup}}

% macros to demarcate lines quoted from TeX source files
\def\beginlines{\par\begingroup\nobreak\medskip\parindent\z@ \obeylines
  \hrule\kern1pt\nobreak \everypar{\strut}}
\def\endlines{\kern1pt\hrule\endgroup\medbreak\noindent}
\def\weakendlines{\kern1pt\hrule\endgroup\medskip\noindent}

\makeatother
% bbnotation


\def\qNIL{{\sx NIL}}
\def\qT{{\sx T}}

\def\qtrue{{\op true}}
\def\qfalse{{\op false}}

\def\qat{\inmmode{\mathinner{\hbox{\op at}}}}
\def\qa{\inmmode{\mathinner{\hbox{\op a}}}}
\def\qaa{\inmmode{\mathinner{\hbox{\op aa}}}}
\def\qd{\inmmode{\mathinner{\hbox{\op d}}}}
\def\qdd{\inmmode{\mathinner{\hbox{\op dd}}}}
\def\qad{\inmmode{\mathinner{\hbox{\op ad}}}}
\def\qada{\inmmode{\mathinner{\hbox{\op ada}}}}
\def\qadd{\inmmode{\mathinner{\hbox{\op add}}}}
\def\qadda{\inmmode{\mathinner{\hbox{\op adda}}}}
\def\qn{\inmmode{\mathinner{\hbox{\op n}}}}

\def\qeq{\inmmode{\mathrel{\hbox{\op eq}}}}
\def\qcons{\inmmode{\mathrel{\raise .3ex\hbox{$\scriptscriptstyle{\bullet}$}}}}
\def\qapp{\inmmode{\mathrel{\ast}}}
%  \def\qlist#1{\langle #1 \rangle}
\def\qlist#1{\inmmode{\mathopen{<} #1 \mathclose{>}}}

\def\qif{\inmmode{\mathinner{\hbox{\op if}}}}
\def\qthen{\inmmode{\mathbin{\hbox{\op then}}}}
\def\qelsif{\inmmode{\mathbin{\hbox{\op else if}}}}
\def\qelse{\inmmode{\mathinner{\hbox{\op else}}}}

%  \def\qequal{\inmmode{\mathrel{\hbox{\op equal}}}}
%  \def\qmem{\inmmode{\mathrel{\hbox{\op mem}}}}

%  \def\qgt{\inmmode{\mathrel{\hbox{\op gt}}}}
%  \def\qlt{\inmmode{\mathrel{\hbox{\op lt}}}}
%  \def\qlte{\inmmode{\mathrel{\hbox{\op lte}}}}
%  \def\qgte{\inmmode{\mathrel{\hbox{\op gte}}}}


%  \def\qor{\inmmode{\mathbin{\hbox{\op or}}}}
%  \def\qand{\inmmode{\mathbin{\hbox{\op and}}}}
%  \def\qnot{\inmmode{\mathinner{\hbox{\op not}}}}

\def\qequal{\inmmode{\mathrel{\dot{=}}}}
\def\qmem{\inmmode{\mathrel{\dot{\in}}}}

\def\qor{\inmmode{\mathrel{\dot{\vee}}}}
\def\qand{\inmmode{\mathrel{\dot{\wedge}}}}
\def\qnot{\inmmode{\mathinner{\dot{\lnot}}}}

\def\qlt{\inmmode{\mathrel{\dot{<}}}}
\def\qlte{\inmmode{\mathrel{\dot{\leq}}}}
\def\qgt{\inmmode{\mathrel{\dot{>}}}}
\def\qgte{\inmmode{\mathrel{\dot{\geq}}}}

\def\qp{\inmmode{\phi}}


\def\mkop#1{\inmmode{\mathinner{\hbox{\it #1}}}}

% quick and dirty mkop
\catcode`/=13 
\def/#1/{\inmmode{\mathinner{\hbox{\it #1}}}}


\def\edefun#1#2{\hbox{!!?? External definition of \mkop{#1} ??!!}}

\makeatletter

\def\begindefun#1#2{%
\par
\noindent\llap{!!??}/#1/??!!
%  \vskip -\abovedisplayskip
$$\let\par=\endgraf \begingroup\smallsize \ttverbatim \parskip=\z@
   \catcode`\|=0  \rightskip-5pc  \defunfinish}

{\catcode`\|=0 |catcode`|\=\other % | is temporary escape character
  |obeylines % end of line is active
  |gdef|defunfinish#1↑↑M#2\enddefun{#1|vbox{#2}|endgroup|endgroup$$}}


\makeatother
% other

\def\limp{\,\rightarrow\,}
\def\liff{\>\leftrightarrow\>}
\def\lor{\,\vee\,}
\def\land{\,\wedge\,}


\def\tabref#1{Table~\ref{#1}}
\def\figref#1{Figure~\ref{#1}}
\def\defref#1{Definition~\ref{#1}}
\def\chapref#1{Chapter~\ref{#1}}
\def\secref#1{Section~\ref{#1}}
\def\bibref#1{(

\def\zz(#1){???}

\def\lisp{{\rm Lisp}}
\def\clisp{{\rm Common\ Lisp}}